package cn.fresh.xuanyuan.module.system.dal.dataobject.wx;

import cn.fresh.xuanyuan.framework.tenant.core.db.TenantBaseDO;
import cn.fresh.xuanyuan.module.system.convert.handler.TemplateDataToStringTypeHandler;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.*;

import java.util.List;

@TableName(value = "system_wx_template", autoResultMap = true)
@Data
@EqualsAndHashCode(callSuper = true)
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class TemplateConfigDO extends TenantBaseDO {

    @TableId(type = IdType.AUTO)
    private Integer id;

    private String appId;

    private String templateId;

    private String remark;

    @TableField(typeHandler = TemplateDataToStringTypeHandler.class)
    private List<WXTemplateDataDO> dataMap;
}
